package middleware

import (
	"github.com/gin-gonic/gin"
	"gitee.com/man0sions/IdCreator/core"
)

func Recvoer() gin.HandlerFunc {
	return func(c *gin.Context) {
		defer func() {
			if err := recover(); err != nil {
				core.Error(nil, err)
			}
		}()


		c.Next()
	}
}
